package oa.hleast.xswl.service.activity;


import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import oa.hleast.xswl.pojo.domain.activity.CmsActivityCalendar;
import oa.hleast.xswl.pojo.domain.activity.CmsUserSignUp;
import oa.hleast.xswl.pojo.form.activity.ActivitySignUpForm;
import oa.hleast.xswl.pojo.vo.activity.ManagerUserSignUpVo;
import oa.hleast.xswl.pojo.vo.activity.ShowUserSignInVo;
import oa.hleast.xswl.pojo.vo.activity.TodayCommonActivityVo;

import java.util.Date;
import java.util.List;

public interface ICmsUserSignUpService extends IService<CmsUserSignUp> {

    boolean add(CmsUserSignUp form);

    boolean update(CmsUserSignUp form);

    Page<CmsUserSignUp> pageList(Integer page, Integer limit, String typeName, Integer display);

    boolean deleteByIds(List<String> asList);

    CmsUserSignUp detail(Long id);

    boolean userSignUp(Long userId, ActivitySignUpForm form);

    @Deprecated
    List<TodayCommonActivityVo> findUserActivity(Long userId);

    List<TodayCommonActivityVo> findAllUserActivity(Long userId);

    List<CmsUserSignUp> findUserByCalendarId(Long activityId);

    List<ShowUserSignInVo> findUserSignInByForCalendar(Long calendarId);

    /**
     * 某场次的报名人数
     */
    Integer countSignUpByCalendar(Long calendarId);

    /**
     * 判断用户是否报名过该场次的活动
     */
    boolean isSignUpByCalendar(Long calendarId, Long userId);

    Boolean updateBodyTemperature(Long signInId, String bodyTemperature);

    Page<ManagerUserSignUpVo> findUserSignUpByForActivityId(Long activityId, Integer page, Integer limit);

    List<TodayCommonActivityVo> findUserActivityByCode(Long userId, String code);

    /**
     * 判断用户是否报名过该活动
     */
    boolean isSignUpByActivityId(Long activityId, Long userId);

    List<TodayCommonActivityVo> findUserVenue(Long userId);

    Date getSIgnInEndDate(CmsActivityCalendar calendar);

    Date getSignInStartDate(CmsActivityCalendar calendar);

    Boolean activityReview(Long id, String review,Long signUpUserId);

    Boolean activityCancel(Long scenesId, Long userId);
}